//index.js
//获取应用实例
const app = getApp()
Page({
  data: {

  },

  onLoad: function (options) {
    if (options != null && options !=

      undefined &&
      options.sharetype != null &&

      options.sharetype > 0) {
      wx.setStorage({
        key: 'merchantId',
        data: {
          merchantId:

            options.merchantId,
        },

        success: function () {
        }

      });
      wx.setStorage({
        key: 'storeId',
        data: {
          storeId: options.storeId,
        },

        success: function () {
        }

      });
      wx.setStorage({
        key: 'qrcodeId',
        data: {
          qrcodeId: options.qrcodeId,
        },

        success: function () {
        }

      });
    }
  },

  Test: function (e) {
    console.log(e.detail.data[0])
    wx.setStorage({
      key: 'userId',
      data: {
        userId: e.detail.data[0],
      },
      success: function () {

      }
    });

  }
})
